package com.itlaobing.demo.servlet;

import javax.servlet.ServletException;
import javax.servlet.annotation.WebServlet;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;

/**
 * @Classname PasswordServlet
 * @Description TODO()
 * @Date 2020/11/11 0011 11:58
 * @Author by Administrator
 * @Version v1.0
 */
@WebServlet("/password")
public class PasswordServlet extends HttpServlet {

    @Override
    protected void doPost(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        /*
              获取密码
              校验两次输入的新密码是否一致
              校验原密码是否正确(可以获取session)
                如果正确，更新数据库数据，更新成功后，跳转登录重新登录
                如果不正确，提示密码不正确
         */
    }
}
